Mining Fix Patterns for FindBugs Violations
نویسندگان
چکیده
Several static analysis tools, such as Splint or FindBugs, have been proposed to the software development community to help detect security vulnerabilities or bad programming practices. However, the adoption of these tools is hindered by their high false positive rates. If the false positive rate is too high, developers may get acclimated to violation reports from these tools, causing concrete and severe bugs being overlooked. Fortunately, some violations are actually addressed and resolved by developers. We claim that those violations fixed recurrently are likely to be true positives, and an automated approach can learn to repair similar unseen violations. In this paper, we first collect and track large-scale fixed and unfixed violations across revisions of software. It turns out that a small number of violation types are responsible for the majority of recurrently occurring violations and they are fixed with similar code changes. To automatically identify patterns in violations and their fixes, we propose an approach that utilizes convolutional neural networks and clustering. We then evaluate the usefulness of the identified fix patterns by applying them to unfixed violations. The results show that actual developers accepted and merged 69 of 116 fixes generated from the fix patterns. From the study, we observe the recurrences of fixed violations that may help prioritize violations, identify fix patterns from existing fixed violations, and resolve similar violations existing
منابع مشابه
Extended Checker for FindBugs
FindBugs is a static analysis tool that examines your class or JAR files looking for potential problems by matching your bytecodes against a list of bug patterns. Although it has displayed valuable efficiency in bug checking, yet it has not provided enough support for the programs using JUnit. This paper tries to fix this problem by extending FindBugs with specific bug pattern detectors to find...
متن کاملKeshmesh: Bringing Advanced Static Analysis to Concurrency Bug Pattern Detectors
Bug patterns are coding idioms that may make the code less maintainable or turn into bugs in future. The state-of-the-art tools for detecting concurrency bug patterns (CBPs) perform simple, intraprocedural analyses. While this simplicity makes the analysis fast, it does not provide protection against CBPs that involve aliasing or multiple methods. This paper introduces a practical and extensibl...
متن کاملMining Patterns and Violations using Concept Analysis
Large programs develop patterns in their implementation and behavior that can be used for defect mining. Previous work used frequent itemset mining to detect such patterns and their violations, which correlate with defects. However, frequent itemset mining gives much more attention to patterns than to the instances of these patterns. We are proposing a more general framework to understand and m...
متن کاملImplementation of Customized FindBugs Detectors
There are a lot of static code analysis tools to automatically find program errors. Traditional techniques usually involve formal methods and complicated computations, and thus suffer from poor extendibility and performance. FindBugs was developed to address these issues. The system is based on the concept of bug patterns, which are claimed to be easy to implement and effective to discover real...
متن کاملCQE - An Approach to Automatically Estimate the Code Quality using an Objective Metric From an Empirical Study
Bugs in a project, at any stage of Software life cycle development are costly and difficult to find and fix. Moreover, the later a bug is found, the more expensive it is to fix. There are static analysis tools to ease the process of finding bugs, but their results are not easy to filter out critical errors and is time consuming to analyze. To solve this problem we used two steps: first to enhan...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
- CoRR
دوره abs/1712.03201 شماره
صفحات -
تاریخ انتشار 2017